const app = getApp();
const Controller = require('../controllers/controllers.js').controller;
Page({
  data: {
    banner:[],
    page:1,
    pageSize:10,
    isEnd:false,
    isloading:true,
    type:1,
  },
  onLoad() {
  },
  onShow(){
  },
  tabs(e){
    this.setData({
      type:e.currentTarget.dataset.type,
    })
  },
  golink(e){
    // if(!wx.getStorageSync('logintoken')){
    //   app.ToLogin()
    //   return
    // }
    wx.navigateTo({
      url:e.currentTarget.dataset.url
    });
  },


  onReachBottom(){
    if(this.data.isEnd){
      return
    }else{
      this.setData({
        page:this.data.page+1
      })
    }
    
  },
  onPageScroll: function (e) { // 获取滚动条当前位置
    
  },
  onShareAppMessage: function (e) {
    
  },
  onShareTimeline: function(res){
    
  },

})